package com.example.agrigreennewssys.dao;

import com.example.agrigreennewssys.entity.ArticleLike;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
@Mapper
public interface ArticleLikeMapper {
//    int isArticleLiked(@Param("articleId") Long articleId, @Param("userId") Long userId);
    int insertArticleLike(ArticleLike articleLike);
    int updateArticleLikeStatus(@Param("articleId") Long articleId, @Param("userId") Long userId, @Param("status") Integer status);
    Integer getArticleLikeStatus(@Param("articleId") Long articleId, @Param("userId") Long userId);

    List<ArticleLike> selectArticleLikeList(@Param("nickName") String nickName, @Param("articleTitle") String articleTitle);

}
